import request from '@/utils/request'

export function list(query) {
  return request({
    url: '/monitor/job/list',
    method: 'get',
    params: query
  })
}

export function run(data) {
  return request({
    url: '/monitor/job/run',
    method: 'post',
    data: data
  })
}

export function changeStatus(data) {
  return request({
    url: '/monitor/job/changeStatus',
    method: 'post',
    data: data
  })
}

export function addJob(data) {
  return request({
    url: '/monitor/job/add',
    method: 'post',
    data: data
  })
}

export function editJob(data) {
  return request({
    url: '/monitor/job/edit',
    method: 'put',
    data: data
  })
}

export function deleteJob(id) {
  return request({
    url: '/monitor/job/remove/'+id,
    method: 'delete'
  })
}


